package cn.terminus.service.customer.kafka;

import cn.terminus.result.common.context.TerminusCallContext;
import cn.terminus.result.common.util.TerminusDateUtils;
import lombok.Data;

@Data
public class KafkaCustomerChannelParam extends StatisticsBase {
    /**
     * 渠道来源
     */
    private String channelResource;
    /**
     * 渠道来源描述
     */
    private String channelResourceName;
    /**
     * 渠道名称
     */
    private String channelName;
    /**
     * 渠道联系人ID
     */
    private Long channelPersonId;
    /**
     * 渠道联系人名称
     */
    private String channelPersonName;
    /**
     * 渠道客户数量
     */
    private Integer customNum;

    private int channelPersonStatus;

    public static KafkaCustomerChannelParam setCustomerChannelMessage(TerminusCallContext context, Long channelPersonId, Integer customNum,int code) {
        KafkaCustomerChannelParam param = new KafkaCustomerChannelParam();
        param.setBusinessId(context.getBusiness().getBusinessId());
        param.setDataTime(TerminusDateUtils.getDate10YMD());
        param.setChannelPersonId(channelPersonId);
//        param.setChannelResource(channelResource);
//        param.setChannelResourceName(channelResourceName);
//        param.setChannelName(channelName);
//        param.setChannelPersonName(channelPersonName);
        param.setCustomNum(customNum);
        param.setChannelPersonStatus(code);
        return param;
    }
}
